﻿<%@ Page Language="C#" MasterPageFile="~/Admin/Admin.Master" AutoEventWireup="true" CodeBehind="Edit.aspx.cs" Inherits="Cn.Cellula.Website.Admin.Content.Template.Edit" Title="编辑模板" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <script type="text/javascript">
    function PageOnLoad(){
        previewTemplate();
    }
    function previewTemplate(){
        var content = $("#"+fixId("txt_Content"));
        var prew = $("#tl_preview");
        if(prew!=null && content!=null){
            prew.innerHTML = content.value;
        }
    }
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="CPH_PageTitle" runat="server">
编辑模板
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="CPH_MainBody" runat="server">
    <div class="action_bar">
        <asp:Button ID="btn_save" runat="server" Text="保存" OnClick="btn_save_Click" />
        <input type="reset" value="重置" />
        <input type="button" onclick="jskitBulter.redirect('Admin/Content/Template/List.aspx')" value="取消" />
    </div>
    <fieldset>
        <legend>模板信息</legend>
        <table border="0" cellpadding="0" cellspacing="0" class="edit_form">
            <tr>
                <td class="edit_form_item_title" style="width:100px">
                    <span class="required">名称：</span>
                </td>
                <td class="edit_form_item_content">
                    <asp:TextBox runat="server" ID="txt_TlName" Width="300px"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td class="edit_form_item_title" style="width:100px">
                    <span class="required">模板内容：</span>
                </td>
                <td class="edit_form_item_content">
                    <asp:TextBox runat="server" TextMode="MultiLine" onblur="previewTemplate()" ID="txt_Content" Width="800px" Height="200"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td class="edit_form_item_title" style="width:100px">
                    备注：
                </td>
                <td class="edit_form_item_content">
                    <asp:TextBox runat="server" TextMode="MultiLine" ID="txt_TlMemo" Width="800px" Height="50"></asp:TextBox>
                </td>
            </tr>
        </table>
    </fieldset>
    <fieldset>
        <legend>预览</legend>
        <table border="0" cellpadding="0" cellspacing="0" class="edit_form">
            <tr>
                <td class="edit_form_item_title" style="width:100px">
                </td>
                <td class="edit_form_item_content">
                    <div id="tl_preview" style="background-color:#ffffff;"></div>
                </td>
            </tr>
        </table>
    </fieldset>
</asp:Content>
